package com.heima.comment.entity;


import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Data;
import org.springframework.data.mongodb.core.mapping.Document;

import java.io.Serializable;
import java.util.Date;


@Data
@Document("ap_comment_repay")
public class ApCommentReply implements Serializable {

    private String id; // id

    private Integer authorId; // 作者id

    private String authorName; // 作者名称
    @JsonSerialize(using = ToStringSerializer.class)
    private Long entryId;// 文章id

    private String commentId;// 类型 0.文章评论 1.动态评论

    private String content;// 评论内容

    private String image;// 头像

    private Long likes = 0L; // 点赞

    private Integer reply = 0; // 回复

    private Integer flag = 0;

    private Date createdTime;

    @TableField(exist = false)
    private Integer operation;// 操作类型 0为点赞  null为未点赞
}
